//
//  WithdrawalTableViewCell.m
//  tuanGG
//
//  Created by 微他 on 15/11/6.
//  Copyright (c) 2015年 weita. All rights reserved.
//

#import "WithdrawalTableViewCell.h"

@implementation WithdrawalTableViewCell
- (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        self.typeImage = [[UIImageView alloc]initWithFrame:CGRectMake(20, 10, 50, 50)];
        [self addSubview:self.typeImage];

        self.type = [[UILabel alloc]initWithFrame:CGRectMake(self.typeImage.frame.size.width+30, 10, ScreenWidth/2, 30)];
        self.type.textColor = [UIColor colorWithHexString:@"#383838"];
        self.type.font = [UIFont systemFontOfSize:15];
        [self addSubview:self.type];

        self.selectedImage = [[UIImageView alloc]initWithFrame:CGRectMake(self.frame.size.width-40, (CGRectGetHeight(self.frame))/2, 23, 23)];
        [self addSubview:self.selectedImage];
        self.codeDetails = [[UILabel alloc]initWithFrame:CGRectMake(_typeImage.frame.size.width+30, CGRectGetMaxY(_type.frame), ScreenWidth-_typeImage.frame.size.width-20, 20)];
        _codeDetails.font =[UIFont systemFontOfSize:13];
        _codeDetails.textColor = [UIColor colorWithHexString:@"#989898"];
        [self addSubview:self.codeDetails];
    }
    return self;
}
- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];
    // Configure the view for the selected state
    if (selected) {
        [self.selectedImage sd_setImageWithURL:nil placeholderImage:IMGNAME(@"选中状态")];
    }else {
        [self.selectedImage sd_setImageWithURL:nil placeholderImage:IMGNAME(@"未选中状态")];
    }
}

@end
